package com.fuqi.android.zhongcai.base.view.activity.deprecated;




import android.app.Activity;
import android.os.Bundle;
import android.util.Log;

import com.fuqi.android.zhongcai.R;
import com.fuqi.android.zhongcai.base.view.widget.HashView;
@Deprecated
public class TestMainActivity extends Activity {
    
	HashView tableView;
	
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_test_main);
        tableView = (HashView) findViewById(R.id.tableView);
        createList();        
        Log.d("MainActivity", "total items: " + tableView.getCount());
        tableView.commit();
    }
    
    private void createList() {
        CustomClickListener listener = new CustomClickListener();
        tableView.setClickListener(listener);
        tableView.addBasicItem("shoucang", "120");
        tableView.addBasicItem("guanzhu", "555");
        tableView.addBasicItem("fav", "2016");
    }
    
    private class CustomClickListener implements HashView.ClickListener {

		@Override
		public void onClick(int index) {
			Log.d("MainActivity", "juner item clicked: " + index);

			
		}
    	
    }
    
}